

        <g:set var="entityName" value="${message(code: 'parent.label', default: 'Parent')}" />
             <g:form action="save" method="post" name="parentCreate">
                <div class="dialog">
                    <table>
                        <tbody>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="student"><g:message code="parent.student.label" default="Student" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: parentInstance, field: 'student', 'errors')}">
                                    <g:select name="student.id" from="${Student.list()}" optionKey="id" value="${parentInstance?.student?.id}"  />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="relation"><g:message code="parent.relation.label" default="Relation" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: parentInstance, field: 'relation', 'errors')}">
                                    <g:lookupSelect id="relation" name="relation" realm="parentrelation" value="${parentInstance?.relation}"/>
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="name"><g:message code="parent.name.label" default="Name" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: parentInstance, field: 'name', 'errors')}">
                                    <g:textField name="name" maxlength="50" value="${parentInstance?.name}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="mobile"><g:message code="parent.mobile.label" default="Mobile" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: parentInstance, field: 'mobile', 'errors')}">
                                    <g:textField name="mobile" value="${parentInstance?.mobile}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="phone"><g:message code="parent.phone.label" default="Phone" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: parentInstance, field: 'phone', 'errors')}">
                                    <g:textField name="phone" value="${parentInstance?.phone}" />
                                </td>
                            </tr>
                        
                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="unit"><g:message code="parent.unit.label" default="Unit" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: parentInstance, field: 'unit', 'errors')}">
                                    <g:textField name="unit" maxlength="250" value="${parentInstance?.unit}" />
                                </td>
                            </tr>

                            <tr class="prop">
                                <td valign="top" class="name">
                                    <label for="unit"><g:message code="parent.post.label" default="Post" /></label>
                                </td>
                                <td valign="top" class="value ${hasErrors(bean: parentInstance, field: 'post', 'errors')}">
                                    <g:textField name="post" maxlength="10" value="${parentInstance?.post}" />
                                </td>
                            </tr>
                        </tbody>
                    </table>
                </div>
                <div class="buttons">
                    <span class="button"><g:submitButton name="create" class="save" value="${message(code: 'default.button.create.label', default: 'Create')}" /></span>
                </div>
            </g:form>